package com.example.app.components.MyButton

import androidx.compose.foundation.interaction.MutableInteractionSource
import androidx.compose.material.IconButton
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.Clear
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.Modifier
import androidx.compose.ui.tooling.preview.Preview
import com.example.app.components.MyIcon.MyIcon

@Composable
fun MyIconButton(
        onClick: () -> Unit,
        modifier: Modifier = Modifier,
        enabled: Boolean = true,
        interactionSource: MutableInteractionSource = remember { MutableInteractionSource() },
        content: @Composable () -> Unit
) {
    IconButton(
        onClick,
        modifier,
        enabled,
        interactionSource,
        content,
    )
}
@Preview
@Composable
fun MyIconButtonDemo() {
    MyIconButton(
        onClick = { /*TODO*/ },
    ) {
        MyIcon(imageVector = Icons.Default.Clear)
    }
}